home *** CD-ROM | disk | FTP | other *** search
/ PCGUIA 114 / PC Guia 114.iso / Software / Utils / The Gimp 2.2.1 / gimp-help-2-0.6-setup.exe / {app} / share / gimp / 2.0 / help / en / ch02s04s07.html < prev    next >
Encoding:
Extensible Markup Language  |  2004-12-19  |  16.1 KB  |  387 lines

  1. <?xml version="1.0" encoding="UTF-8" standalone="no"?>
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4.   <head>
  5.     <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  6.     <title>4.7.┬áPaths</title>
  7.     <link rel="stylesheet" href="gimp-help-plain.css" type="text/css" />
  8.     <link rel="stylesheet" href="gimp-help-screen.css" type="text/css" />
  9.     <meta name="generator" content="DocBook XSL Stylesheets V1.66.1" />
  10.     <link rel="start" href="index.html" title="GIMP User Manual" />
  11.     <link rel="up" href="ch02s04.html" title="4.┬áWorking with Images" />
  12.     <link rel="prev" href="ch02s04s06.html" title="4.6.┬áGrids and Guides" />
  13.     <link rel="next" href="ch02s04s08.html" title="4.8.┬áBrushes" />
  14.   </head>
  15.   <body>
  16.     <div xmlns="" class="navheader">
  17.       <table width="100%" summary="Navigation header">
  18.         <tr>
  19.           <th colspan="3" align="center" id="chaptername">4.┬áWorking with Images</th>
  20.         </tr>
  21.         <tr>
  22.           <td width="20%" align="left"><a accesskey="p" href="ch02s04s06.html">Prev</a>┬á</td>
  23.           <th width="60%" align="center" id="sectionname">4.7.┬áPaths</th>
  24.           <td width="20%" align="right">┬á<a accesskey="n" href="ch02s04s08.html">Next</a></td>
  25.         </tr>
  26.       </table>
  27.       <hr />
  28.     </div>
  29.     <div class="sect2" lang="en" xml:lang="en">
  30.       <div class="titlepage">
  31.         <div>
  32.           <div>
  33.             <h3 class="title"><a id="gimp-paths"></a>4.7.┬áPaths</h3>
  34.           </div>
  35.         </div>
  36.       </div>
  37.       <a id="id3422811" class="indexterm"></a>
  38.       <div class="informalfigure">
  39.         <div class="mediaobject">
  40.           <img src="../images/using/path-examples.png" />
  41.           <div class="caption">
  42.             <p>
  43.            Four examples of GIMP paths: one closed and polygonal; one
  44.            open and polygonal; one closed and curved; one with a mixture
  45.            of straight and curved segments.
  46.         </p>
  47.           </div>
  48.         </div>
  49.       </div>
  50.       <p>
  51.     A <span class="emphasis"><em>path</em></span> is a one-dimensional curve.  Paths are
  52.     used for two main purposes:
  53.   </p>
  54.       <div class="itemizedlist">
  55.         <ul type="disc">
  56.           <li>
  57.             <p>
  58.         A closed path can be converted into a selection.
  59.       </p>
  60.           </li>
  61.           <li>
  62.             <p>
  63.         An open or closed path can be <span class="emphasis"><em>stroked</em></span>,
  64.         that is, painted on the image, in a variety of ways.
  65.       </p>
  66.           </li>
  67.         </ul>
  68.       </div>
  69.       <p>
  70.     Paths can be created and manipulated using the <a href="ch03s06.html#gimp-tool-path" title="6.1.┬áPath Tool">Path tool</a>.  Paths, like layers and
  71.     channels, are components of an image.  When an image is saved in
  72.     GIMP's native XCF file format, any paths it has are saved along
  73.     with it.  The list of paths in an image can be viewed and operated
  74.     on using the <a href="ch04s04.html" title="4.┬áPath dialog">Paths
  75.     dialog</a>.  If you want to move a path from one image to
  76.     another, you can do so by copying and pasting using the popup menu
  77.     in the Paths dialog, or by dragging an icon from the Paths dialog
  78.     into the destination image's window.
  79.   </p>
  80.       <div class="informalfigure">
  81.         <div class="mediaobject">
  82.           <img src="../images/using/path-with-anchors.png" />
  83.           <div class="caption">
  84.             <p>
  85.            Appearance of a path while it is being manipulated using the
  86.            Path tool.  Black squares are anchor points, the open circle
  87.            is the selected anchor, and the two open squares are its
  88.            handles.  Note that this path has two components.
  89.         </p>
  90.           </div>
  91.         </div>
  92.       </div>
  93.       <p>
  94.     GIMP paths belong to a mathematical type called "Bezier paths".
  95.     What this means in practical terms is that they are defined by
  96.     <span class="emphasis"><em>anchors</em></span> and <span class="emphasis"><em>handles</em></span>.
  97.     "Anchors" are points the path goes through.  "Handles" define the
  98.     direction of a path when it enters or leaves an anchor point:
  99.     each anchor point has two handles attached to it.  
  100.   </p>
  101.       <p>
  102.     Paths can be very complex.  If you create them by hand using the
  103.     Path tool, unless you are obsessive they probably won't contain
  104.     more than a few dozen anchor points (often many fewer); but if you
  105.     create them by transforming a selection into a path, or by
  106.     transforming text into a path, the result can easily contain
  107.     hundreds of anchor points, or even thousands.
  108.   </p>
  109.       <p>
  110.     A path may contain multiple <span class="emphasis"><em>components</em></span>.  A
  111.     "component" is a part of a path whose anchor points are all
  112.     connected to each other by path segments.  The ability to have
  113.     multiple components in paths allows you to convert them into
  114.     selections having multiple disconnected parts.
  115.   </p>
  116.       <p>
  117.     Each component of a path can be either <span class="emphasis"><em>open</em></span>
  118.     or <span class="emphasis"><em>closed</em></span>: "closed" means that the last
  119.     anchor point is connected to the first anchor point.  If you
  120.     transform a path into a selection, any open components are
  121.     automatically converted into closed components by connecting the
  122.     last anchor point to the first anchor point with a straight line.
  123.   </p>
  124.       <p>
  125.     Path segments can be either straight or curved.  A path all of
  126.     whose segments are straight is called "polygonal".  When you
  127.     create a path segment, it starts out straight, because the handles
  128.     for the anchor points are intially placed directly on top of the
  129.     anchor points, yielding handles of zero length, which produce
  130.     straight-line segments.  You can make a segment curved by dragging
  131.     a handle away from one of the anchor points.
  132.   </p>
  133.       <p>
  134.     One nice thing about paths is that they are very light in terms of
  135.     resource consumption, especially in comparison with images.
  136.     Representing a path in RAM only requires storing the
  137.     coordinates of its anchors and handles:  1K of memory is enough to
  138.     hold quite a complex path, but not enough to hold even a 20x20
  139.     pixel RGB layer.  Therefore, it is quite possible to have
  140.     literally hundreds of paths in an image without putting any
  141.     signficant stress of your system.  (How much stress managing them
  142.     would put on <span class="emphasis"><em>you</em></span> is, of course, another
  143.     question.)  Even a path with thousands of segments consumes
  144.     minimal resources in comparison to a typical layer or channel.
  145.   </p>
  146.       <div class="simplesect" lang="en" xml:lang="en">
  147.         <div class="titlepage">
  148.           <div>
  149.             <div>
  150.               <h4 class="title"><a id="id3423030"></a>Paths and Selections</h4>
  151.             </div>
  152.           </div>
  153.         </div>
  154.         <p>
  155.       GIMP lets you transform the selection for an image into a path;
  156.       it also lets you transform paths into selections.  For
  157.       information about the selection and how it works, see the <a href="ch02s04s04.html" title="4.4.┬áThe Selection">Selection</a> section.
  158.     </p>
  159.         <p>
  160.       When you transform a selection into a path, the path closely
  161.       follows the "marching ants".  Now, the selection is a
  162.       two-dimensional entity, but a path is a one-dimensional entity,
  163.       so there is no way to transform the selection into a path
  164.       without losing information.  In fact, any information about
  165.       partially selected areas (i.e., feathering) will be lost when
  166.       the selection is turned into a path.  If the path is transformed
  167.       back into a selection, the result is an all-or-none selection,
  168.       similar to what would be obtained by executing "Sharpen" from
  169.       the Select menu.
  170.     </p>
  171.       </div>
  172.       <div class="simplesect" lang="en" xml:lang="en">
  173.         <div class="titlepage">
  174.           <div>
  175.             <div>
  176.               <h4 class="title"><a id="id3423068"></a>Stroking a Path</h4>
  177.             </div>
  178.           </div>
  179.         </div>
  180.         <div class="informalfigure">
  181.           <div class="mediaobject">
  182.             <img src="../images/using/path-stroking-examples.png" />
  183.             <div class="caption">
  184.               <p>
  185.              The four paths from the top illustration, each stroked in a
  186.              different way.
  187.           </p>
  188.             </div>
  189.           </div>
  190.         </div>
  191.         <p>
  192.       Paths do not alter the appearance of the image pixel data unless
  193.       they are <span class="emphasis"><em>stroked</em></span>, using
  194.       <span class="guimenu">Edit</span>-><span class="guimenuitem">Stroke Path</span>
  195.       from the image menu or the Paths dialog right-click menu, or the
  196.       "Stroke Path" button in the Tool Options dialog for the Path
  197.       tool.  
  198.     </p>
  199.         <p>
  200.       Choosing "Stroke Path" by any of these means brings up a dialog
  201.       that allows you to control the way the stroking is done.  You
  202.       can choose from a wide variety of line styles, or you can stroke
  203.       with any of the Paint tools, including unusual ones such as the
  204.       Clone tool, Smudge tool, Eraser, etc.
  205.     </p>
  206.         <p>
  207.       You can further increase the range of stroking effects by
  208.       stroking a path multiple times, or by using lines or brushes of different
  209.       widths.  The possibilities for getting interesting effects in
  210.       this way are almost unlimited.
  211.     </p>
  212.       </div>
  213.       <div class="simplesect" lang="en" xml:lang="en">
  214.         <div class="titlepage">
  215.           <div>
  216.             <div>
  217.               <h4 class="title"><a id="id3423148"></a>Transforming Paths</h4>
  218.             </div>
  219.           </div>
  220.         </div>
  221.         <p>
  222.       Each of the Transform tools (Rotate, Scale, Perspective, etc)
  223.       can be set to act specifically on paths, using the "Affect:"
  224.       option in the tool's Tool Options dialog.  This gives you a
  225.       powerful set of methods for altering the shapes of paths without
  226.       affecting other elements of the image.
  227.     </p>
  228.         <p>
  229.       By default a Transform tool, when it is set to affect paths,
  230.       only acts on a single path:  the <span class="emphasis"><em>active
  231.       path</em></span> for the image, which is shown highlighted in the
  232.       Paths dialog.  You can make a transformation affect more than
  233.       one path, and possibly other things as well, using the
  234.       "transform lock" buttons in the Paths dialog.  Not only paths,
  235.       but also layers and channels, can be transform-locked.  If you
  236.       transform one element that is transform-locked, all others will
  237.       be transformed in the same way.  So, for example, if you want to
  238.       scale a layer and a path by the same amount, click the
  239.       transform-lock buttons so that "chain" symbols appear next to
  240.       the layer in the Layers dialog, and the path in the Paths
  241.       dialog; then use the Scale tool on either the layer or the path,
  242.       and the other will automatically follow.  
  243.     </p>
  244.       </div>
  245.       <div class="simplesect" lang="en" xml:lang="en">
  246.         <div class="titlepage">
  247.           <div>
  248.             <div>
  249.               <h4 class="title"><a id="id3423188"></a>Paths and Text</h4>
  250.             </div>
  251.           </div>
  252.         </div>
  253.         <div class="informalfigure">
  254.           <div class="mediaobject">
  255.             <img src="../images/using/path-from-text.png" />
  256.             <div class="caption">
  257.               <p>
  258.             Text converted to a path and then transformed using the
  259.             Perspective tool.
  260.           </p>
  261.             </div>
  262.           </div>
  263.         </div>
  264.         <div class="informalfigure">
  265.           <div class="mediaobject">
  266.             <img src="../images/using/path-text-stroked.png" />
  267.             <div class="caption">
  268.               <p>
  269.            The path shown above, stroked with a fuzzy brush and then
  270.            gradient-mapped using the Gradient Map filter with the
  271.            "Yellow Contrast" gradient.
  272.           </p>
  273.             </div>
  274.           </div>
  275.         </div>
  276.         <p>
  277.       A text item created using the Text tool can be transformed into
  278.       a path using the "Create path from text" button in the Tool
  279.       Options for the Text tool.  This can be useful for several
  280.       purposes, including:
  281.     </p>
  282.         <div class="itemizedlist">
  283.           <ul type="disc">
  284.             <li>
  285.               <p>
  286.           Stroking the path, which gives you many possibilities for
  287.           fancy text.
  288.         </p>
  289.             </li>
  290.             <li>
  291.               <p>
  292.           More importantly, transforming the text.  Converting text
  293.           into a path, then transforming the path, and finally either
  294.           stroking the path or converting it to a selection and
  295.           filling it, often leads to much higher-quality results than
  296.           rendering the text as a layer and transforming the pixel
  297.           data. 
  298.         </p>
  299.             </li>
  300.           </ul>
  301.         </div>
  302.       </div>
  303.       <div class="simplesect" lang="en" xml:lang="en">
  304.         <div class="titlepage">
  305.           <div>
  306.             <div>
  307.               <h4 class="title"><a id="id3423273"></a>Paths and SVG files</h4>
  308.             </div>
  309.           </div>
  310.         </div>
  311.         <p>
  312.       SVG, standing for "Scalable Vector Graphics", is an increasingly
  313.       popular file format for <span class="emphasis"><em>vector graphics</em></span>, in
  314.       which graphical elements are represented in a
  315.       resolution-independent format, in contrast to <span class="emphasis"><em>raster
  316.       graphics</em></span>, in which graphical elements are represented
  317.       as arrays of pixels.  GIMP is mainly a raster graphics program,
  318.       but paths are vector entities.
  319.     </p>
  320.         <p>
  321.       Fortunately, paths are represented in SVG files in almost
  322.       exactly the same way they are represented in GIMP.  (Actually
  323.       fortune has nothing to do with it:  GIMP's path handling was
  324.       rewritten for GIMP 2.0 with SVG paths in mind.)  This
  325.       compatibility makes it possible to store GIMP paths as SVG files
  326.       without losing any information.   You can access this capability
  327.       in the Paths dialog.
  328.     </p>
  329.         <p>
  330.       It also means that GIMP can create paths from SVG files saved in
  331.       other programs, such as <span class="application">Inkscape</span> or
  332.       <span class="application">Sodipodi</span>, two popular open-source
  333.       vector graphics applications.  This is nice because those
  334.       programs have much more powerful path-manipulation tools than
  335.       GIMP does.  You can import a path from an SVG file using the
  336.       Paths dialog.
  337.     </p>
  338.         <p>
  339.       The SVG format handles many other graphical elements than just
  340.       paths:  among other things, it handles figures such as squares,
  341.       rectangles, circles, ellipses, regular polygons, etc.  GIMP 2.0
  342.       cannot do anything with these entities, but GIMP 2.2 can load
  343.       them as paths.
  344.     </p>
  345.         <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
  346.           <table border="0" summary="Note">
  347.             <tr>
  348.               <td rowspan="2" align="center" valign="top" width="25">
  349.                 <img alt="[Note]" src="../images/note.png" />
  350.               </td>
  351.               <th align="left">Note</th>
  352.             </tr>
  353.             <tr>
  354.               <td colspan="2" align="left" valign="top">
  355.                 <p>
  356.       Creating paths is not the only thing GIMP can do with SVG
  357.       files.  It can also open SVG files as GIMP images, in the usual
  358.       way. 
  359.       </p>
  360.               </td>
  361.             </tr>
  362.           </table>
  363.         </div>
  364.       </div>
  365.     </div>
  366.     <div class="navfooter">
  367.       <hr />
  368.       <table width="100%" summary="Navigation footer">
  369.         <tr>
  370.           <td width="40%" align="left"><a accesskey="p" href="ch02s04s06.html">Prev</a>┬á</td>
  371.           <td width="20%" align="center">
  372.             <a accesskey="u" href="ch02s04.html">Up</a>
  373.           </td>
  374.           <td width="40%" align="right">┬á<a accesskey="n" href="ch02s04s08.html">Next</a></td>
  375.         </tr>
  376.         <tr>
  377.           <td width="40%" align="left" valign="top">4.6.┬áGrids and Guides┬á</td>
  378.           <td width="20%" align="center">
  379.             <a accesskey="h" href="index.html">Home</a>
  380.           </td>
  381.           <td width="40%" align="right" valign="top">┬á4.8.┬áBrushes</td>
  382.         </tr>
  383.       </table>
  384.     </div>
  385.   </body>
  386. </html>
  387.